package com.smartcommunity.dao.fullSearch;

import java.util.List;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import com.smartcommunity.entity.fullSearch.SearchHistory;

/**
 * @ClassName: SearchHistoryDao
 * @Description: 全息档案搜索历史接口
 * @author: yangyi
 * @Date: 2020/7/6 13:34
 * @Company:
 * @version V2.0.1
 */
@Mapper
public interface SearchHistoryDao {

	/**
	 * 新增搜索历史
	 */
	void saveSearchHistory(SearchHistory searchHistory);
	
	/**
	 * 由用户ID查找搜索历史总数
	 */
	Integer countUserHistory(@Param("userId")Integer userId);
	
	/**
	 * 由用户ID查找搜索历史
	 */
	List<SearchHistory> listUserHistory(@Param("startRow")Integer startRow, @Param("endRow")Integer endRow, @Param("userId")Integer userId);
	
	/**
	 * 查找搜索历史
	 */
	List<SearchHistory> findSearchHistory(SearchHistory searchHistory);
	
	/**
	 * 删除搜索历史
	 * @param searchHistory
	 */
	void delSearchHistory(SearchHistory searchHistory);
}
